package com.tz.colawallet.basecode.util;

import android.content.Context;
import android.widget.Toast;

/**
 * Created by dell on 2017/10/31.
 */

public class ToastUtil {

    private static Toast mToast = null;

    public static void showText(Context context, int resId) {
        showText(context, context.getString(resId));
    }

    public static void showText(Context context, String text) {
        if (mToast == null)
            mToast = Toast.makeText(context, text, Toast.LENGTH_SHORT);
        else
            mToast.setText(text);
        mToast.show();
    }
}
